{template "header.html"}

<form id="myform" class="form-horizontal" style="padding: 0 30px; margin-top: -20px">
    <div class="form-body">
        <div class="form-group">
            {$select}
        </div>
        <div class="form-actions">
            <div class="row">
                <div class="col-md-3">
                    <div class="form-group" style="margin-bottom:5px">
                        <label> {dr_lang('按用户账号')} </label>
                    </div>
                    <div class="form-group">
                        <label><input type="text" name="username" class="form-control"></label>
                    </div>
                </div>
                <div class="col-md-3">
                    <div class="form-group" style="margin-bottom:5px">
                        <label> {dr_lang('按用户uid')} </label>
                    </div>
                    <div class="form-group">
                        <label><input type="text" name="uid" class="form-control"></label>
                    </div>
                </div>

                <div class="col-md-6">
                    <div class="form-group" style="margin-bottom:5px">
                        <label> {dr_lang('按id范围')} </label>
                    </div>
                    <div class="form-group">
                        <label><input type="text" name="id1" class="form-control"></label>
                        <label>{dr_lang('到')}</label>
                        <label><input type="text" name="id2" class="form-control"></label>
                    </div>
                </div>

                <div class="col-md-12">
                    <div class="form-group" style="margin-bottom:5px">
                        <label> {dr_lang('自定义条件')} </label>
                    </div>
                    <div class="form-group">
                        <textarea class="form-control" style="height:100px" name="sql"></textarea>
                        <p style="padding-top:9px;" class="help-block"> {dr_lang('支持自定义条件的SQL语句')} </p>
                    </div>
                </div>

                <div class="col-md-12" style="text-align:center;padding-top:20px">
                    <button type="button" onclick="dr_content_submit_todo()" class="btn red"> <i class="fa fa-trash"></i> {dr_lang('立即执行')}</button>
                </div>
            </div>
        </div>
    </div>
</form>
<script>
    function dr_content_submit_todo() {
        window.location.href = '{$todo_url}&'+$('#myform').serialize()
    }
</script>

{template "footer.html"}